home *** CD-ROM | disk | FTP | other *** search
/ The Game Master (3rd Edition) / The Game Master 3rd edition.iso / files / demo_vga / utilega2 / kc-pal.doc < prev    next >
Encoding:
Text File  |  1986-06-09  |  4.2 KB  |  84 lines

  1. ¢4 L                                      KC-PAL
  2.                                   Version 01FEB86
  3.  
  4.          The program, KC-PAL, gives the user the ability to changes the
  5.          EGA's color palettes through a fancy form screen.  But first, some
  6.          background information:
  7.  
  8.                                 What is a palette:
  9.          A palette is a holding place in the EGA hardware to save a color
  10.          setting.  The EGA uses 4 palettes for 64k (EGA memory) and 16
  11.          palettes for 128k+ (EGA memory).  This means that EGA can have up
  12.          to 4/16 different colors on the screen at a time.  The EGA (any
  13.          size of memory) can produce sixtyfour different colors on the
  14.          Enhance Color Display (ECD).  So a palette holds the value of one
  15.          of these sixtyfour diffent colors.  Now in text mode (the above
  16.          was about 640x350 graphic mode) all EGA's can have 16 palettes (or
  17.          16 different colors on the screen).  The palettes are arranged on
  18.          the screen as:
  19.                           8   9  10  11  12  13  14  15
  20.                           0   1   2   3   4   5   6   7
  21.  
  22.           What is a color:
  23.               A color is made up of three primary color, Red, Green and
  24.           Blue.  EGA has four setting (with the ECD) for each primary
  25.           color (0,1,2 and 3).  Four different Red, Green and Blue pri-
  26.           mary colors equals 64 different colors (4 * 4 * 4 = 64). Each
  27.           palette can be assign one of these 64 different colors.  The
  28.           bottow on the screen contains the break down of the current
  29.           palette selected (reversed highlighed) as:
  30.  
  31.                     R = X, G = X, B = X     { X = 0 through 3 }
  32.  
  33.           What is a color number:
  34.               A color number is the values of the Red, Green and Blue
  35.           (RGB) primary colors put together for form a single number.
  36.           For example: R = 2, G = 1, B = 0 =
  37.                        16 * R + 4 * G + B  =
  38.                        16 * 2 + 4 * 1 + 0  = 38
  39.  
  40.           The default EGA colors are arranged on the screen as:
  41.  
  42.                          56  57  58  59  60  61  62  63
  43.                           0   1   2   3   4   5   6   7
  44.  
  45.           KC-PAL commands:
  46.                   'space bar':  Reset all colors to their default state.
  47.  
  48.                   'arrow keys': Select palette to change.  The reversed
  49.                                 highlighted cursor will move to the current
  50.                                 palette and the information line will change.
  51.  
  52.                   '+' or '-':   Adds one or subtract one from the current
  53.                                 palettes 'color number'.
  54.  
  55.                   'R' 'G' 'B':  Adds one to the specified primary color.
  56.                                 Watch the information line as you do it.
  57.  
  58.                   '0'..'9':     Allows you to enter a new color number.
  59.                                 For a single digit number, you must enter
  60.                                 a zero first.
  61.  
  62.                   'ESC':        Return to DOS with palettes set.
  63.  
  64.           If you use KC-PAL alot, KCSETPAL (with or without parameters) will
  65.           allow KC-PAL to read the old palette setting, put KCSETPAL in your
  66.           autoexec.bat file.  If you do not use KCSETPAL, KC-PAL will reset
  67.           the palettes to their default state when executed.
  68.  
  69.           If you exit KC-PAL ('ESC') and the palettes are diffent from their
  70.           default state then it will display the parameters for the program
  71.           KCSETPAL.
  72.  
  73.           Please note that KC-PAL is design for an EGA with more than 64k
  74.           of graphic memory.  It will still work, but not totally.  This
  75.           version KC-PAL was design to demonstrate my graphic library in
  76.           graphic mode.  A new version of KC-PAL that will work of any
  77.           EGA with be available by the time you read this.  If you find
  78.           KC-PAL a problem with 64k of EGA memory send a SASE disk for
  79.           the new version.
  80.                                     Kent Cedola
  81.                               2015 Meadow Lake Court
  82.                                 Norfolk, VA  23518
  83.                                   (804) 857-0613   ¢0 L
  84.